<!DOCTYPE html>
<html lang="zh-cn"
      xmlns:th="http://www.thymeleaf.org"
      xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity5">
<head th:fragment="head">
    <title>Factory</title>
    <meta charset="utf-8"/>
    <link rel="stylesheet" href="/css/main.css"/>
    <script type="text/javascript" src="/js/jquery-3.7.0.min.js"></script>
</head>
<body>
<div th:fragment="top" style="height:50px;">
    <div style="float:left;display:flex;">
        <img src="/images/logo.jpg" style="height:50px;">
        <b style="font-size:22px;padding-top:12px;font-family:cursive;">山海电气</b>
    </div>
    <div class="logout" sec:authorize="isAuthenticated()">
        用户: <span sec:authentication="name"></span> |
        角色: <span sec:authentication="principal.authorities"></span> |
        <form th:action="@{/logout}" method="post" style="display:inline">
            <input type="submit" value="退出"/>
        </form>
    </div>
</div>
</body>
</html>